#include "SplitTool.h"
#include "cppjieba/Jieba.hpp"
SplitTool::SplitTool(){}
SplitToolCppJieba::SplitToolCppJieba(){}
vector<string> SplitToolCppJieba::cut(string content) {
    const char* const DICT_PATH = "/home/zzh/cpp/project/v1_project/search/src/dict/jieba.dict.utf8";
    const char* const HMM_PATH = "/home/zzh/cpp/project/v1_project/search/src/dict/hmm_model.utf8";
    const char* const USER_DICT_PATH = "/home/zzh/cpp/project/v1_project/search/src/dict/user.dict.utf8";
    const char* const IDF_PATH = "/home/zzh/cpp/project/v1_project/search/src/dict/idf.utf8";
    const char* const STOP_WORD_PATH = "/home/zzh/cpp/project/v1_project/search/src/dict/stop_words.utf8";
    cppjieba::Jieba jieba(DICT_PATH,
        HMM_PATH,
        USER_DICT_PATH,
        IDF_PATH,
        STOP_WORD_PATH);
    //string sentence = "我从北京清华大学来，去北京航空航天大学";
    vector<string> words;
    jieba.Cut(content,words,true);
    return words;
}